<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/

// 前台首页
Route::get('/','Home\IndexController@index');


// 前台注册
Route::Controller('/Home','Home\LoginController');


//前台个人中心
Route::Controller('/home/user','Home\UserController');

//前台购物车添加操作
Route::Controller('/home/cart','home\CartController');

//前台结算页操作
Route::Controller('/home/order','home\OrderController');

//前台订单结算页操作
Route::Controller('/home/address','home\AddressController');

//显示订单支付
Route::get('/order/index/{dd}','Home\OrderController@index');



// 验证码
Route::get('/Vcode','Home\LoginController@Vcode');

// 发送邮件
Route::get('/mail','Home\LoginController@sendMail');
// Route::get('/mail','Home\LoginController@findMail');

// 邮箱激活
Route::get('/jihuo','Home\LoginController@jihuo');

// 邮箱找回密码
Route::get('/find','Home\LoginController@find');

// 前台商品列表
Route::Controller('/home/goods','Home\GoodsController');


	// 后台路由组
Route::group(['middleware'=>'AdminLogin'],function(){

//后台首页
Route::get('/admin/','admin\IndexController@index');

//后台用户管理
Route::Controller('/admin/user','admin\UserController');

//后台分类管理
Route::Controller('/admin/cate','admin\CateController');

//后台商品管理
Route::Controller('/admin/goods','admin\GoodsController');

//后台订单管理
Route::Controller('/admin/order','admin\OrderController');

});

// 后台登录
Route::Controller('/admin/login','Admin\LoginController');